package com.kpf.springcloud.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.kpf.springcloud.pojo.KpfTopicComment;
import org.apache.ibatis.annotations.Param;

/**
 * @author shiwen
 * @date 2021/3/10
 */
public interface TopicCommentMapper extends BaseMapper<KpfTopicComment> {

    /**
     * 根据用户id删除所有的信息
     *
     * @param userId
     */
    void deleteByUserId(int userId);

    /**
     * 根据帖子id和用户id进行删除
     *
     * @param topicId
     */
    void deleteByTopicId(@Param("topicId") int topicId);

}